package com.life.view;

import java.util.HashMap;

import javax.swing.JComponent;

public class WidgetRegistry {

	
	private static WidgetRegistry thisRef = null;
	private HashMap<String,Object>map =null;
	
	private WidgetRegistry()
	{
		map = new  HashMap<String,Object>();
	}
	
	public static WidgetRegistry getInstance()
	{
		if(thisRef == null)
		{
			thisRef = new WidgetRegistry();
		}
		
		return thisRef;
	}
	
	public Object get(String key)
	{
		return map.get(key);
	}
	
	public void put(String key, Object widget)
	{
		map.put(key,widget);
	}
	
	
}
